Skip to content

[RFC-0010] Add multi-tenant workload identity support for AWS Bucket #1868

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

cappyzawa
Copy link
Member

@cappyzawa cappyzawa added area/bucket Bucket related issues and pull requests area/api API related issues and pull requests labels Aug 13, 2025
@cappyzawa cappyzawa force-pushed the feat/bucket-workload-identity-aws branch 3 times, most recently from d550312 to 3e0213c Compare August 13, 2025 18:36
@cappyzawa cappyzawa force-pushed the feat/bucket-workload-identity-aws branch from 3e0213c to 3300705 Compare August 13, 2025 19:08
@cappyzawa cappyzawa marked this pull request as ready for review August 13, 2025 19:24
Copy link
Member

@matheuscscp matheuscscp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good overall, thanks!

@@ -273,6 +273,55 @@ data:
secretkey: <BASE64>
```

##### AWS Controller-Level Workload Identity example
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's mention specifically https://fluxcd.io/flux/integrations/aws/#for-amazon-simple-storage-service as well like we did for GCP

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should add the link eventually. However, the current documentation at that URL (specifically the "At the object level" section) states that S3 integration with the Bucket API "does not support configuring authentication through OIDC Federation at the object level" and will be introduced in Flux v2.7.

Since this PR is implementing that functionality, I'll include the link in this PR and update the website documentation afterward to reflect the new capabilities. This way users will have the reference ready once the website is updated.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed via 794228f .

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll include the link in this PR and update the website documentation afterward

Cool, thanks! We have an item for tracking this in the umbrella issue:

Screenshot from 2025-08-14 14-24-21

This PR should update all three cloud providers 🙏

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’ve made the same update for Azure as well: 3a14ce4

@cappyzawa cappyzawa force-pushed the feat/bucket-workload-identity-aws branch 4 times, most recently from 9fe7486 to ef755b2 Compare August 14, 2025 06:52
@matheuscscp
Copy link
Member

Let's not delete this much documentation on this PR, in the past we considered deleting all Workload Identity related documentation and just linking to the full guide and decided not to do that in that moment, we need more time to think how we will do this.

Can you please reset to this commit? 3300705

This one was looking pretty good, I'd like to reboot the review starting from that one

@cappyzawa cappyzawa force-pushed the feat/bucket-workload-identity-aws branch from 3a14ce4 to 29b4242 Compare August 14, 2025 14:43
…Bucket

Remove os.Setenv() to prevent env var pollution

Remove os.Setenv() call that could cause environment variable
pollution in multi-tenant environments. The pkg/auth/aws package
already handles region configuration properly by prioritizing
opts.STSRegion over AWS_REGION environment variable.

Signed-off-by: cappyzawa <[email protected]>
@cappyzawa cappyzawa force-pushed the feat/bucket-workload-identity-aws branch from 29b4242 to 6dd483d Compare August 14, 2025 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/api API related issues and pull requests area/bucket Bucket related issues and pull requests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants